package com.cj.Mapper;

import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.cj.models.UserLevelModel;
import org.apache.ibatis.annotations.Insert;
import org.apache.ibatis.annotations.Param;
import org.springframework.stereotype.Repository;

@Repository
public interface UserLevelMapper extends BaseMapper<UserLevelModel> {


    @Insert("insert into user_level(user_name,user_level) " +
            "values(#{userlevel.userName},#{userlevel.userLevel}) " +
            "on duplicate key update user_level=#{userlevel.userLevel}")
    public int upgrade(@Param("userlevel") UserLevelModel userLevelModel);


}
